#include<iostream>
#include<vector>

using namespace std;

int fib(int N) {
    if (N == 0) {
        return 0;
    } else if (N == 1) {
        return 1;
    } else {
        return fib(N - 1) + fib(N - 2);
    }
}
int main(int argc, char const *argv[])
{
    int N;
    cin >> N;
    cout << fib(N) << endl;
    return 0;
}
